<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>巨丰布业 V 1.0.0</title>
    <!-- <script src="./vue.js"></script> -->
    <script src="https://cdn.jsdelivr.net/npm/vue@2"></script>
    <script src="https://cdn.jsdelivr.net/npm/dayjs@latest"></script>
    <!-- <script src="https://unpkg.com/swiper@8/swiper-bundle.min.js"> </script> -->
    <!-- <link rel="stylesheet" href="https://unpkg.com/swiper@8/swiper-bundle.min.css"> -->
    <script src="https://cdn.jsdelivr.net/npm/echarts@5.4.2/dist/echarts.min.js"></script>
    <!-- <script src="https://unpkg.com/dayjs@1.8.21/dayjs.min.js"></script> -->
    <script src="https://cdnjs.cloudflare.com/ajax/libs/axios/0.24.0/axios.min.js"></script> <!-- 使用 CDN 引入 axios -->
    <style>
        html,
        body {
            margin: 0;
            padding: 0;
        }

        .page-wrap {
            position: relative;
            width: 100vw;
            height: 100vh;
            overflow: hidden;
            background-color: #030a1d;
            background: #000113;
        }

        .page {
            background: url('./static/images/back.jpg') no-repeat;
            left: 50%;
            top: 50%;
            transform-origin: left top;
            transform: translate(-50%, -50%);
            background-size: 100% 100%;
            width: 1920px;
            height: 1080px;
            position: absolute;
            display: flex;
            flex-direction: column;
        }

        /* //上面主要部分 */
        .content-box {
            display: flex;
        }

        .h-text {
            color: #8f96b2;
            position: absolute;
            top: 2%;
            left: 2%;
            font-weight: 600;
        }

        .h-title {
            color: #fff;
            font-weight: 700;
            font-size: 36px;
            position: absolute;
            top: 4%;
            left: 46%;
        }

        .h-date {
            color: #8f96b2;
            position: absolute;
            top: 2%;
            left: 86%;
            font-weight: 600;
        }

        .h-time {
            color: #fff;
            font-weight: 600;
            font-size: 24px;
            position: absolute;
            top: 1.6%;
            left: 94%;
        }

        .c-left {
            top: 12.5%;
            left: 4%;
        }

        .c-right {
            top: 12.5%;
            left: 71%;
        }

        .f-left {
            top: 58.5%;
            left: 4%;
        }

        .f-content {
            top: 58.5%;
            left: 34%;
        }

        .f-right {

            top: 58.5%;
            left: 71%;

        }

        .absquanj {
            position: absolute;
            color: #83a1d9;
            font-weight: 600;
            font-size: 20px;
        }

        /* 染整中心 */
        .h-left-box {
            position: absolute;
            top: 16.5%;
            left: 2%;
            /* background-color: antiquewhite; */
            width: 28.5%;
            height: 38.5%;
            padding: 0 40px;
            box-sizing: border-box;
        }

        /* 染整中心订单 */
        .h-content-DyeingAndFinishingCenterOrder {
            position: absolute;
            top: 11.5%;
            left: 33%;
            width: 9%;
            height: 14%;
            display: flex;
            justify-content: center;
            align-items: center;
            flex-flow: column wrap
        }

        /* 同比增长数量 */
        .h-content-Year-on-yearIncrease {
            position: absolute;
            top: 11.5%;
            left: 43%;
            width: 6%;
            height: 7.5%;
            display: flex;
            justify-content: center;
            align-items: center;
            flex-flow: column;
        }

        /* 同比增长率 */
        .h-content-Year-on-yearGrowthRate {
            position: absolute;
            top: 19.5%;
            left: 43%;
            width: 6%;
            height: 6%;
            display: flex;
            justify-content: center;
            align-items: center;
            flex-flow: column;
        }

        .flex-center-column {
            display: flex;
            justify-content: center;
            align-items: center;
            flex-flow: column;
        }

        /* 制造中心单 */
        .h-content-ManufacturingCenterList {
            position: absolute;
            top: 11.5%;
            left: 51.5%;
            width: 9.5%;
            height: 14%;
        }

        /* 同比增长数量左 */
        .h-content-Year-on-yearIncrease1 {
            position: absolute;
            top: 11.5%;
            left: 61.5%;
            width: 6%;
            height: 7.5%;

        }

        /* 同比增长率右 */
        .h-content-Year-on-yearGrowthRate1 {
            position: absolute;
            top: 19.5%;
            left: 61.5%;
            width: 6%;
            height: 6%;
        }

        /* 订单走势 */
        .h-right-box {
            position: absolute;
            top: 16.5%;
            left: 69.5%;
            width: 28.5%;
            height: 38.5%;
            padding: 0 40px;
            box-sizing: border-box;
        }

        /* 织造中心 */
        .h-content-OrderTrend {
            position: absolute;
            top: 27.5%;
            left: 33%;
            width: 34.5%;
            height: 27.5%;
        }

        /* 待出货订单 */
        .f-left-box {
            position: absolute;
            top: 62.5%;
            left: 2%;
            width: 28.5%;
            height: 31.5%;
            padding: 0px 20px;
            box-sizing: border-box;
            overflow: auto;
        }

        /* 客户订单查询 */
        .f-content-box {
            position: absolute;
            top: 62.5%;
            left: 32.5%;
            width: 35%;
            height: 31.5%;
            overflow: hidden;
        }

        /* 企业实力 */
        .f-right-box {
            position: absolute;
            top: 63.5%;
            left: 70.2%;
            width: 27%;
            height: 30%;
        }

        .swiper {
            width: 100%;
            height: 100%;
        }

        .hlb-h {
            width: 100%;
            height: 40%;
            display: flex;
            flex-flow: row;
            flex-flow: row wrap;
        }

        .hlb-h-box {
            width: 50%;
            height: 50%;
            display: flex;
            flex-flow: column;
            justify-content: center;
        }

        .hlb-title {
            font-size: 16px;
            color: #90a6c7;
            margin-bottom: 5px;
        }

        .hlb-text {
            font-size: 32px;
            font-weight: 700;
            color: #23e1f9;
        }


        .hcl-title {
            color: #fff;
            font-weight: 600;
            font-size: 18px;
            margin-bottom: 18px;
        }

        .hcl-text {
            color: #24d8da;
            font-weight: 700;
            font-size: 32px;
        }

        .hct-title {
            color: #90a6c7;
            margin-bottom: 8px;
        }

        .hct-text {
            color: #24d8da;
            font-size: 22px;
            font-weight: 700;
        }

        .hct-content {
            display: flex;
            width: 100%;
            justify-content: space-around;
            align-items: center;
            font-size: 22px;
            font-weight: 700;
        }

        .hct-rate {
            color: #90a6c7;
        }

        .c-20b2e9 {
            color: #20b2e9;
        }

        .c-0986c7 {
            color: #0986c7;
        }

        .c-09cac3 {
            color: #09cac3;
        }

        .c-feb247 {
            color: #feb247;
        }

        .c-224bdf {
            color: #224bdf;
        }

        .c-f8b262 {
            color: #f8b262;
        }

        .c-3698d8 {
            color: #3698d8;
        }

        .c-1cdbd3 {
            color: #1cdbd3;
        }

        table {
            width: 100%;
            table-layout: fixed;
            /* 只有定义了表格的布局算法为fixed，下面td的定义才能起作用。 */
        }

        td,
        th {
            border: none;
            text-align: center;
            color: #86a5c6;
            width: 16%;
        }

        td {
            width: 16%;
            padding: 10px 4px;
            box-sizing: border-box;
            word-break: keep-all;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis
        }

        th {
            padding: 20px 10px;
        }

        thead {
            width: 100%;
            position: sticky;
            top: 0;
            z-index: 1;
        }

        ::-webkit-scrollbar {
            display: none;
        }

        .swiper-img {
            width: 100%;
            height: 100%;
        }

        #DyeingAndFinishingCenterBarChart {
            width: 100%;
            height: 55%;
        }

        #OrderTrend {
            width: 100%;
            height: 100%;
        }

        #QualityTrend {
            width: 100%;
            height: 55%;
        }

        #SalesMap {
            width: 130%;
            height: 130%;
            position: relative;
            top: -17%;
            left: -13%;
        }
    </style>
</head>

<body>
    <div class="page-wrap" id="app">
        <div ref="screen-wrap" class="page">
            <div class="title"></div>
            <div class="content-box">
                <div class="h-text"> 巨丰布业 V 1.0.0</div>
                <div class="h-title">巨丰布业</div>
                <div class="h-date">{{date}}</div>
                <div class="h-time">{{time}}</div>
                <div class="c-left absquanj">染整中心</div>
                <div class="c-right absquanj">织造中心</div>
                <div class="f-left absquanj">待出货订单</div>
                <div class="f-content absquanj">销售地图</div>
                <div class="f-right absquanj">企业实力</div>
                <!-- /* 染整中心 */ -->
                <div class="h-left-box">
                    <div class="hlb-h">
                        <div class="hlb-h-box">
                            <div class="hlb-title">当月订单数量</div>
                            <div class="hlb-text">{{DyeingAndFinishiData.orderqty || 0}}</div>
                        </div>
                        <div class="hlb-h-box">
                            <div class="hlb-title">准交缸数</div>
                            <div class="hlb-text c-20b2e9">{{DyeingAndFinishiData.batchnum || 0}}</div>
                        </div>
                        <div class="hlb-h-box">
                            <div class="hlb-title">空闲产能</div>
                            <div class="hlb-text c-0986c7">{{DyeingAndFinishiData.freeqty || 0}}</div>
                        </div>

                        <div class="hlb-h-box">
                            <div class="hlb-title">当月客户准交</div>
                            <div class="hlb-text c-09cac3">{{DyeingAndFinishiData.rate || 0}}</div>
                        </div>
                    </div>
                    <div id="DyeingAndFinishingCenterBarChart"></div>
                </div>
                <!-- /* 染整中心订单 */ -->
                <div class="h-content-DyeingAndFinishingCenterOrder">
                    <div class="hcl-title">染整中心订单</div>
                    <div class="hcl-text">{{DyeingAndFinishiData.rOrderqty || 0}}</div>
                </div>
                <!-- /* 同比增长数量 */ -->
                <div class="h-content-Year-on-yearIncrease">
                    <div class="hct-title">同比增长数量</div>
                    <div class="hct-text">{{DyeingAndFinishiData.increaseMoney || 0}}</div>
                </div>
                <!-- /* 同比增长率 */ -->
                <div class="h-content-Year-on-yearGrowthRate">
                    <div class="hct-title">同比增长率</div>
                    <div class="hct-content">
                        <div class="hct-text">{{DyeingAndFinishiData.increaseMoneyRate || 0}}</div>
                        <div class="hct-rate">%</div>
                    </div>
                </div>
                <!-- /* 制造中心订单 */ -->
                <div class="h-content-ManufacturingCenterList flex-center-column">
                    <div class="hcl-title">织造中心订单</div>
                    <div class="hcl-text c-feb247">{{DyeingAndFinishiData.tableBiSums || 0}}</div>
                </div>
                <!-- /* 同比增长数量左 */ -->
                <div class="h-content-Year-on-yearIncrease1 flex-center-column">
                    <div class="hct-title">同比增长数量</div>
                    <div class="hct-text c-feb247">{{DyeingAndFinishiData.increaseMoney2 || 0}}</div>
                </div>
                <!-- /* 同比增长数量右 */ -->
                <div class="h-content-Year-on-yearGrowthRate1 flex-center-column">
                    <div class="hct-title">同比增长率</div>
                    <div class="hct-content">
                        <div class="hct-text c-feb247">{{DyeingAndFinishiData.increaseMoneyRate2 || 0}}</div>
                        <div class="hct-rate">%</div>
                    </div>
                </div>
                <!-- /* 订单走势 */ -->
                <div class="h-content-OrderTrend">
                    <div id="OrderTrend"></div>
                </div>
                <!-- /* 织造中心 */ -->
                <div class="h-right-box">
                    <div class="hlb-h">
                        <div class="hlb-h-box">
                            <div class="hlb-title">当月订单数量</div>
                            <div class="hlb-text c-224bdf">{{DyeingAndFinishiData.bphzl || 0}}</div>
                        </div>
                        <div class="hlb-h-box">
                            <div class="hlb-title">当月客户准交</div>
                            <div class="hlb-text c-1cdbd3">{{DyeingAndFinishiData.zlpi || 0}}</div>
                        </div>
                        <div class="hlb-h-box">
                            <div class="hlb-title">降等率</div>
                            <div class="hlb-text c-f8b262">{{DyeingAndFinishiData.jdpi || 0}}%</div>
                        </div>
                        <div class="hlb-h-box">
                            <div class="hlb-title">疵点率</div>
                            <div class="hlb-text c-3698d8">{{DyeingAndFinishiData.cdpi || 0}}%</div>
                        </div>
                    </div>
                    <div id="QualityTrend"></div>
                </div>
                <!-- /* 待出货订单 */ -->
                <div class="f-left-box">
                    <table border="0" style="border-collapse: collapse;">
                        <thead>
                            <tr style="background: #05233f;">
                                <th>出货单号</th>
                                <th>贸易商</th>
                                <th>出货日期</th>
                                <th>仓库</th>
                                <th>条数</th>
                                <th>重量</th>
                            </tr>
                        </thead>
                        <tbody>
                            <tr v-for="(item,index) in PendingOrderList" :key="index">
                                <td>{{item.NO}}</td>
                                <td>{{item.LocalName}}</td>
                                <td>{{item.CDate }}</td>
                                <td>{{item.HouseName}}</td>
                                <td>{{item.SumStrips}}</td>
                                <td>{{item.SumWeightQty}}</td>
                            </tr>
                        </tbody>
                    </table>
                </div>
                <!-- /* 客户订单查询 */ -->
                <div class="f-content-box">
                    <div id="SalesMap"></div>
                </div>
                <!-- /* 企业实力 */ -->
                <div class="f-right-box">
                    <video height="100%" width="100%" autoplay="" loop="" controls="" muted=""
                        src="http://120.196.185.227:7576/api/minio/file/download/zzy/6e6e8314217d4c499cdeef9ed5b50bc6.mp4"></video>
                </div>
            </div>
        </div>
    </div>
    <script type="text/javascript" src="./china.js"></script>
    <script>

        new Vue({
            el: "#app",
            data() {
                return {
                    date: '',
                    time: '',
                    url: 'http://120.196.185.227:7576/api/',
                    PendingOrderList: [],
                    DyeingAndFinishiData: {},
                    dyeWorksMonth: [],
                    orderqty: [],
                    freeqty: [],
                    batchnum: [],
                    rate: [],
                    // 染厂走势
                    TrendOfDyeingPlant: [],
                    // 染厂走势
                    TrendsOfTextileMills: [],
                    // 走势
                    trendMonth: [],
                    trendMonth1: [],
                    TrendsOfTextileMillscdpi: [],
                    DyeingAndFinishingmyChart: null,
                    QualityTrendmyChart: null,
                    OrderTrendmyChart: null,
                    OrderTrendoption: null,
                    QualityTrendoption: null,
                    DyeingAndFinishingoption: null
                };
            },
            mounted() {
                window.addEventListener('resize', this.throttle(() => { this.setScale() }, 100)), this.setScale();
                setInterval(() => {
                    this.date = dayjs().format('YYYY年MM月DD日')
                    this.time = dayjs().format('HH:mm')
                }, 1000)
                // //轮播图
                // var mySwiper = new Swiper('.swiper', {
                //     direction: 'horizontal',
                //     loop: true, // 循环模式选项
                //     autoplay: true,
                // })
                // 销售地图
                this.SalesMap()
                // 染整中心
                // setInterval(this.DyeingAndFinishingCenter(), 30 * 60 * 1000);
                setInterval(() => {
                    this.DyeingAndFinishingCenter()
                }, 30 * 60 * 1000)
                //染整中心柱状图
                this.BarChart()
                //订单走势折线图
                this.OrderTrend()
                //品质走势折线图
                this.QualityTrend()
                this.DyeingAndFinishingCenter()
                // 待出货订单
                // this.PendingOrder()
            },
            beforeDestroy() {
                window.removeEventListener('resize', this.setScale)
            },
            methods: {
                DyeingAndFinishingCenter() {
                    this.orderqty = []
                    this.batchnum = []
                    this.freeqty = []
                    this.rate = []
                    this.dyeWorksMonth = []
                    this.TrendsOfTextileMills = []
                    this.TrendOfDyeingPlant = []
                    this.trendMonth = []
                    axios.post(this.url + 'apiReport/ordertj/ordertjReport')
                        .then(response => {
                            // 请求成功的处理逻辑
                            const { singleMap, salesDelivery, ordert1, ordert2, ordert3 } = response.data.data.list
                            this.DyeingAndFinishiData = singleMap
                            this.PendingOrderList = salesDelivery
                            // for()
                            // ordert1.map((item, index) => {
                            //     console.log(index)
                            //     console.log(item)
                            // })
                            for (let key in ordert1) {
                                // 当月订单数量
                                this.orderqty.push(ordert1[key][0].orderqty)
                                // 当月准交缸数
                                this.batchnum.push(ordert1[key][0].batchnum)
                                // 当月空闲数量
                                this.freeqty.push(ordert1[key][0].freeqty)
                                // 当月客户准交
                                this.rate.push(ordert1[key][0].rate)
                                this.dyeWorksMonth.push(key)
                            }
                            for (let key in ordert2) {
                                // 染厂走势
                                this.TrendOfDyeingPlant.push(ordert2[key][0].orderqty)
                                this.trendMonth.push(key)
                            }
                            for (let key in ordert3) {
                                // 织厂走势
                                this.TrendsOfTextileMills.push(ordert3[key][0].bphzl)
                                this.TrendsOfTextileMillscdpi.push(ordert3[key][0].cdpi)
                                this.trendMonth1.push(key)
                            }
                            //左
                            this.DyeingAndFinishingoption.series[0].data = this.orderqty
                            this.DyeingAndFinishingoption.series[1].data = this.batchnum
                            this.DyeingAndFinishingoption.series[2].data = this.freeqty
                            this.DyeingAndFinishingoption.series[3].data = this.rate
                            this.DyeingAndFinishingoption.xAxis.data = this.dyeWorksMonth
                            //中
                            this.OrderTrendoption.series[0].data = this.TrendOfDyeingPlant
                            this.OrderTrendoption.series[1].data = this.TrendsOfTextileMills
                            this.OrderTrendoption.xAxis.data = this.trendMonth
                            // 右
                            this.QualityTrendoption.series[0].data = this.TrendsOfTextileMillscdpi
                            this.QualityTrendoption.xAxis.data = this.trendMonth1
                            
                            this.OrderTrendmyChart.setOption(this.OrderTrendoption);
                            this.QualityTrendmyChart.setOption(this.QualityTrendoption);
                            this.DyeingAndFinishingmyChart.setOption(this.DyeingAndFinishingoption);
                        })
                        .catch(error => {
                            // 请求失败的处理逻辑
                            console.log(error);
                        });
                },
                // 销售地图
                SalesMap() {
                    echarts.registerMap('china', jsonData);
                    var chart = echarts.init(document.getElementById('SalesMap'));
                    let iconRQ = "";
                    let curveness = -0.4;//调整弧线弧度
                    var geoCoordMap = {
                        '黑龙江': [127.9688, 45.368, 48209.4, 22321.2, 19598.7, 30213.2, 2521.2, 1343.5, 6321.6, 1842.1, 832.9, 90129.3],
                        '内蒙古': [110.3467, 41.4899, 59371.6, 23395.9, 18461.6, 29101.3, 510.5, 779.0, 688.4, 897.4, 202.6, 101229.1],
                        "吉林": [125.8154, 44.2584, 459391.2, 24591.4, 16846.6, 28589.4, 2296.9, 228.8, 1580.4, 259.8, 661.8, 500829.2],
                        '北京': [116.4551, 40.2539, 64368.7, 25737.1, 25712.1, 28573.9, 791.8, 817.1, 4888.7, 783.7, 60.2, 0],
                        "辽宁": [123.1238, 42.1216, 48097.3, 19734.3, 16816.1, 28330.2, 1513.5, 278.1, 6055.0, 1414.1, 700.9, 84647.7],
                        "河北": [114.4995, 38.1006, 40866.2, 17336.9, 16846.2, 28320.4, 840.3, 598.8, 1058.6, 330.5, 814.0, 75049.3],
                        "天津": [117.4219, 39.4189, 30964.4, 14341.5, 13482.1, 28262.8, 1437.9, 721.5, 4372.5, 627.2, 767.2, 58788],
                        "山西": [112.3352, 37.9413, 33211.8, 11435.8, 10818.7, 28256.7, 2109.7, 341.2, 5955.1, 1321.5, 402.3, 55466.3],
                        "陕西": [109.1162, 34.2004, 35714.9, 10814.4, 10459.4, 28135.4, 1251.3, 1262.7, 2871.5, 1334.4, 442.1, 56988.7],
                        "甘肃": [103.5901, 36.3043, 39459.1, 11358.6, 10410.8, 28123.4, 417.7, 1135.6, 172.1, 374.3, 415.8, 61228.5],
                        "宁夏": [106.3586, 38.1775, 41869.0, 11961.8, 10586.4, 28068.3, 1120.6, 1267.5, 3768.9, 1750.2, 208.1, 76164.1],
                        "青海": [101.4038, 36.8207, 48412.1, 14671.2, 13080.8, 28015.4, 2310.9, 982.4, 4577.3, 1709.5, 84.1, 76164.1],
                        "新疆": [87.9236, 43.5883, 45938.4, 21869.1, 20580.3, 27942.3, 2105.6, 1217.5, 4485.3, 461.7, 115.6, 88387.8],
                        "西藏": [91.11, 29.97, 43365.9, 23439.1, 22309.3, 27887.7, 2425.9, 905.6, 2855.7, 957.8, 410.0, 89114.3],
                        "四川": [103.9526, 30.7617, 51939.6, 25734.6, 24733.1, 27864.5, 418.7, 775.7, 969.3, 1533.8, 285.6, 102407.3],
                        "重庆": [108.3843, 30.4397, 48410.9, 24618.3, 22808.0, 27730.2, 82.3, 1117.8, 1573.9, 392.3, 122.6, 95837.2],
                        "山东": [117.1582, 36.8701, 48096.1, 19309.1, 18306.3, 27592.8, 1044.9, 849.7, 2270.3, 918.8, 424.5, 85711.5],
                        "河南": [113.4668, 34.6234, 45736.9, 19315.6, 17309.8, 27580.5, 1605.4, 136.6, 4704.7, 247.6, 142.2, 82362.3],
                        "江苏": [118.8062, 31.9208, 53080.8, 22185.9, 21830.8, 27357.2, 628.1, 192.0, 5492.4, 1012.8, 728.3, 97097.5],
                        "安徽": [117.29, 32.0581, 43080.6, 19308.0, 19081.0, 27230.3, 209.6, 968.5, 2151.5, 442.8, 60.1, 81469.6],
                        "湖北": [114.3896, 30.6628, 48094.1, 21808.1, 20308.0, 26754.7, 355.6, 1318.8, 3087.1, 1167.9, 288.2, 90210.2],
                        "浙江": [119.5313, 29.8773, 55821.3, 23698.1, 22337.0, 26471.4, 1955.7, 324.7, 2323.9, 592.2, 538.0, 2],
                        "福建": [119.4543, 25.9222, 53644.6, 24933.1, 23093.6, 26322.2, 1302.6, 863.1, 2475.2, 1585.8, 472.9, 101671.3],
                        "江西": [116.0046, 28.6633, 49616.3, 21843.9, 20803.4, 25755.4, 640.8, 1038.6, 4206.9, 227.6, 212.2, 92263.6],
                        "湖南": [113.0823, 28.2568, 51893.9, 21415.9, 20280.9, 25617.6, 2336.6, 543.0, 2940.5, 1412.1, 233.5, 93590.7],
                        "贵州": [106.6992, 26.7682, 45866.2, 23435.6, 22308.1, 25416.8, 1755.2, 1307.7, 1401.5, 31.2, 251.7, 91609.9],
                        "云南": [102.9199, 25.4663, 48099.1, 18664.1, 16130.8, 25255.3, 1796.4, 694.9, 3368.8, 1199.3, 402.2, 82894],
                        "广东": [113.1224, 23.0095, 62143.3, 25593.9, 24893.4, 25249.2, 1840.5, 347.1, 237.2, 1490.7, 530.4, 112630.6],
                        "广西": [108.479, 23.1152, 44618.5, 18684.3, 17808.1, 24761.5, 808.0, 374.1, 2422.5, 165.5, 500.7, 81110.9],
                        "海南": [110.3893, 19.8516, 55823.9, 25583.7, 24686.8, 24559.2, 1614.0, 1208.0, 784.1, 1337.4, 25.0, 95458.1],
                        '上海': [121.4648, 31.2891, 64643.5, 28096.4, 2718.3, 24524.4, 720.9, 1236.0, 4808.8, 393.2, 143.8, 106094.4],
                        '台湾': [121.5651, 25.0377, 24643.5, 147348.6, 13080.8, 24419.3, 667.2, 1100.0, 4976.4, 820.2, 210.2, 185072.9],
                        '香港': [114.1466, 22.2701, 46147.4, 24614.3, 24590.5, 24395.4, 406.2, 171.1, 5021.7, 1793.3, 580.2, 95352.2],
                        '澳门': [113.5495, 22.1918, 43464.3, 24935.8, 22812.1, 23987.3, 2519.4, 1110.3, 2692.8, 889.1, 704.1, 91212.2]
                    };
                    let data = [{
                        name: "新疆",
                        value: [12, 23, 12]
                    },
                    {
                        name: "湖北",
                        value: [12, 1, 12]
                    },

                    {
                        name: "重庆",
                        value: [12, 1, 12]
                    },
                    {
                        name: "浙江",
                        value: [12, 1, 12]
                    },
                    {
                        name: "台湾",
                        value: [12, 1, 12]
                    },
                    {
                        name: "湖南",
                        value: [12, 1, 12]
                    },
                    {
                        name: "北京",
                        value: [12, 1, 12]
                    },
                    {
                        name: "浙江",
                        value: [12, 1, 12]
                    },
                    {
                        name: "四川",
                        value: [12, 1, 12]
                    },
                    {
                        name: "云南",
                        value: [12, 1, 12]
                    },
                    {
                        name: "青海",
                        value: [12, 1, 12]
                    },
                    {
                        name: "西藏",
                        value: [12, 1, 12]
                    },
                    {
                        name: "山东",
                        value: [12, 1, 12]
                    },
                    ];
                    data.push(
                        {
                            name: "广东",
                            value: [0, 0, 0]
                        }
                    )
                    let lineData = [];
                    data.forEach(e => {
                        let list = [], posistion = geoCoordMap[e.name];
                        list = posistion.slice(0, 2).concat(e.value);
                        e.value = list;
                        lineData.push({
                            fromName: "广东",
                            toName: e.name,
                            value: e.value,
                            coords: [
                                geoCoordMap["广东"],
                                posistion.slice(0, 2)


                            ]
                        })
                    })
                    chart.setOption({
                        backgroundColor: '#000f1e',
                        tooltip: {
                            trigger: 'item',
                            backgroundColor: 'rgba(166, 200, 76, 0.82)',
                            borderColor: '#FFFFCC',
                            showDelay: 0,
                            hideDelay: 0,
                            enterable: true,
                            transitionDuration: 0,
                            extraCssText: 'z-index:100',
                            formatter: function (params, ticket, callback) {
                                //根据业务自己拓展要显示的内容
                                if (params.seriesType == "lines") {
                                    return params.data.fromName + ' > ' + params.data.toName
                                } else {
                                    return ""
                                }
                            }
                        },
                        geo: {
                            map: 'china',
                            aspectScale: 0.85,
                            layoutCenter: ["50%", "50%"], //地图位置
                            layoutSize: '100%',
                            itemStyle: {
                                normal: {
                                    shadowColor: 'rgba(11,192,251,0.8)',
                                    shadowOffsetX: 0,
                                    shadowOffsetY: 15,
                                    opacity: 0.5,
                                },
                                emphasis: {
                                    areaColor: 'rgba(9,231,249,0.5)',
                                }
                            },
                            regions: [{
                                name: '南海诸岛',
                                itemStyle: {
                                    areaColor: 'rgba(0, 10, 52, 1)',
                                    borderColor: 'rgba(0, 10, 52, 1)',
                                    normal: {
                                        opacity: 0,
                                        label: {
                                            show: false,
                                            color: "#009cc9",
                                        }
                                    },
                                },
                                label: {
                                    show: false,
                                    color: '#FFFFFF',
                                    fontSize: 12,
                                },
                            }],
                        },
                        series: [
                            // 常规地图
                            {
                                type: 'map',
                                mapType: 'china',
                                aspectScale: 0.85,
                                layoutCenter: ["50%", "50%"], //地图位置
                                layoutSize: '100%',
                                zoom: 1, //当前视角的缩放比例
                                // roam: true, //是否开启平游或缩放
                                scaleLimit: { //滚轮缩放的极限控制
                                    min: 1,
                                    max: 2
                                },
                                itemStyle: {
                                    normal: {
                                        areaColor: 'rgba(5,135,177,0.6)',
                                        borderColor: '#1cccff',
                                        borderWidth: 1,//隐藏省界线
                                        borderColor: "#3FBCCE",
                                        shadowColor: 'rgba(56,192,255,0.3)',
                                        shadowBlur: 50

                                    },
                                    emphasis: {
                                        areaColor: 'rgba(5,216,252,0.5)',
                                        label: {
                                            color: "#fff"
                                        }
                                    }
                                },


                            },
                            { //首都星图标
                                name: 'gd',
                                type: 'scatter',

                                coordinateSystem: 'geo',
                                data: [{
                                    name: '首都',
                                    value: [113.14, 23.08],

                                },],
                                symbol: iconRQ, //气泡
                                symbolSize: 20,
                                showAllSymbol: true,
                                label: {
                                    normal: {
                                        show: false,

                                    },
                                    emphasis: {
                                        show: false
                                    }
                                },

                            },
                            // 区域散点图
                            {
                                type: 'effectScatter',
                                coordinateSystem: 'geo',
                                zlevel: 2,
                                symbolSize: 2,
                                rippleEffect: { //坐标点动画
                                    period: 0,
                                    scale: 0,
                                    brushType: 'fill'
                                },
                                label: {
                                    normal: {
                                        show: true,
                                        position: 'right',
                                        formatter: '{b}',
                                        color: '#b3e2f2',
                                        fontSize: 12
                                    }
                                },

                                data: data,


                            },
                            // 线 和 点
                            {
                                type: 'lines',
                                zlevel: 1, //设置这个才会有轨迹线的小尾巴

                                effect: {
                                    show: true,
                                    period: 3,
                                    trailLength: 0.1,
                                    color: '#fff', //流动点颜色
                                    symbol: 'arrow',
                                    symbolSize: 6
                                },
                                lineStyle: {
                                    type: "dotted",
                                    normal: {
                                        color: '#fff', //线条颜色
                                        width: 1, //线条宽度
                                        opacity: 0.1, //尾迹线条透明度
                                        curveness: curveness //尾迹线条曲直度
                                    }
                                },
                                data: lineData
                            },
                        ]
                    });


                },
                OrderTrend() {
                    var chartDom = document.getElementById('OrderTrend');
                    this.OrderTrendmyChart = echarts.init(chartDom);
                    this.OrderTrendoption =
                    {
                        title: {
                            text: '',
                        },
                        tooltip: {
                            trigger: 'axis',
                        },
                        legend: {
                            data: [
                                { name: '染整订单走势', textStyle: { color: '#24d8da' } },
                                { name: '织造订单走势', textStyle: { color: '#feb247' } },
                            ],
                            left: 'right'
                        },
                        grid: {
                            left: '2%',
                            right: '2%',
                            bottom: '0%',
                            top: '10%',
                            containLabel: true,
                        },
                        color: ['#24d8da', '#feb247'],
                        xAxis: {
                            type: 'category',
                            data: this.trendMonth,
                            axisLine: {
                                lineStyle: {
                                    color: '#ffffffbf',
                                },
                            },
                        },
                        yAxis: {
                            type: 'value',
                            axisLine: {
                                lineStyle: {
                                    color: '#ffffffbf',
                                    width: 2,
                                },
                            },
                            splitLine: {
                                show: false
                            },
                            axisLine: {
                                show: true, //不显示坐标轴线
                                lineStyle: {
                                    color: "#fff",
                                }
                            },
                        },
                        series: [
                            {
                                name: '染整订单走势',
                                type: 'line',
                                data: this.TrendOfDyeingPlant,
                                symbolSize: 0,
                                smooth: true,
                                // areaStyle: {
                                //     color: '#3678b1ab',
                                // },
                                color: '#24d8da',
                            },
                            {
                                name: '织造订单走势',
                                type: 'line',
                                data: this.TrendsOfTextileMills,
                                symbolSize: 0,
                                smooth: true,
                                // areaStyle: {
                                //     color: '#3678b1cc',
                                // },
                                color: '#feb247',
                            },
                        ],
                    }
                    // this.OrderTrendoption && this.OrderTrendmyChart.setOption(this.OrderTrendoption);
                },
                QualityTrend() {
                    var chartDom = document.getElementById('QualityTrend');
                    this.QualityTrendmyChart = echarts.init(chartDom);
                    this.QualityTrendoption =
                    {
                        title: {
                            text: '',
                        },
                        tooltip: {
                            trigger: 'axis',
                        },
                        legend: {
                            data: [
                                { name: '品质走势', textStyle: { color: '#feb247' } },
                            ],
                            left: 'right'
                        },
                        grid: {
                            left: '2%',
                            right: '0%',
                            bottom: '0%',
                            top: '20%',
                            containLabel: true,
                        },
                        color: ['#feb247'],
                        xAxis: {
                            type: 'category',
                            data: this.trendMonth1,
                            axisLine: {
                                lineStyle: {
                                    color: '#ffffffbf',
                                },
                            },
                        },
                        yAxis: {
                            type: 'value',
                            axisLine: {
                                lineStyle: {
                                    color: '#ffffffbf',
                                    width: 2,
                                },
                            },
                            splitLine: {
                                show: false
                            },
                            axisLine: {
                                show: true, //不显示坐标轴线
                                lineStyle: {
                                    color: "#fff",
                                }
                            },
                        },
                        series: [
                            {
                                name: '品质走势',
                                type: 'line',
                                data: this.TrendsOfTextileMillscdpi,
                                symbolSize: 0,
                                smooth: true,
                                areaStyle: {
                                    color: '#eeac51d9',
                                },
                                color: '#feb247',
                            },
                        ],
                    }
                    // this.QualityTrendoption && this.QualityTrendmyChart.setOption(this.QualityTrendoption);
                },
                BarChart() {
                    var chartDom = document.getElementById('DyeingAndFinishingCenterBarChart');
                    this.DyeingAndFinishingmyChart = echarts.init(chartDom);
                    this.DyeingAndFinishingoption = {
                        tooltip: {
                            trigger: 'axis',
                        },
                        xAxis: {
                            type: 'category',
                            data: this.dyeWorksMonth,
                            axisLine: {
                                lineStyle: {
                                    color: "#fff",
                                }
                            }
                        },
                        yAxis: {
                            type: 'value',
                            splitLine: {
                                show: false
                            },
                            axisLine: {
                                show: true, //不显示坐标轴线
                                lineStyle: {
                                    color: "#fff",
                                }
                            },

                        },
                        grid: {
                            left: '0%',
                            right: '0%',
                            bottom: '0%',
                            top: '20%',
                            containLabel: true,
                        },
                        series: [
                            {
                                name: '订单数量',
                                type: 'bar',
                                barWidth: 10,
                                barGap: '20%',
                                emphasis: {
                                    focus: 'series'
                                },
                                data: this.orderqty,
                                itemStyle: {
                                    normal: {
                                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                            // 四个数字分别对应 数组中颜色的开始位置，分别为 右，下，左，上。例如（1,0,0,0 ）代表从右边开始渐
                                            // 变。offset取值为0~1，0代表开始时的颜色，1代表结束时的颜色，柱子表现为这两种颜色的渐变。
                                            offset: 0,
                                            color: '#02799a'
                                        }, {
                                            offset: 1,
                                            color: '#02c4e0'
                                        }]),
                                        label: {
                                            formatter: '{c}',
                                            show: true,
                                            position: 'top',
                                            textStyle: {
                                                fontSize: '10',
                                                color: '#fff',
                                            },
                                        },
                                    }
                                },

                            },
                            {
                                name: '准交缸数',
                                type: 'bar',
                                barWidth: 10,

                                emphasis: {
                                    focus: 'series'
                                },
                                data: this.batchnum,
                                itemStyle: {
                                    normal: {
                                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                            // 四个数字分别对应 数组中颜色的开始位置，分别为 右，下，左，上。例如（1,0,0,0 ）代表从右边开始渐
                                            // 变。offset取值为0~1，0代表开始时的颜色，1代表结束时的颜色，柱子表现为这两种颜色的渐变。
                                            offset: 0,
                                            color: '#03a8df'
                                        }, {
                                            offset: 1,
                                            color: '#055b97'
                                        }]),
                                        label: {
                                            formatter: '{c}',
                                            show: true,
                                            position: 'top',
                                            textStyle: {
                                                fontSize: '10',
                                                color: '#fff',
                                            },
                                        },
                                    }
                                },
                            },
                            {
                                name: '空闲数量',
                                barWidth: 10,
                                type: 'bar',
                                emphasis: {
                                    focus: 'series'
                                },
                                data: this.freeqty,
                                itemStyle: {
                                    normal: {
                                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                            // 四个数字分别对应 数组中颜色的开始位置，分别为 右，下，左，上。例如（1,0,0,0 ）代表从右边开始渐
                                            // 变。offset取值为0~1，0代表开始时的颜色，1代表结束时的颜色，柱子表现为这两种颜色的渐变。
                                            offset: 0,
                                            color: '#07458a'
                                        }, {
                                            offset: 1,
                                            color: '#0271b6'
                                        }]),
                                        label: {
                                            formatter: '{c}',
                                            show: true,
                                            position: 'top',
                                            textStyle: {
                                                fontSize: '10',
                                                color: '#fff',
                                            },
                                        },
                                    }
                                },
                            },
                            {
                                name: '客户准交',
                                barWidth: 10,
                                type: 'bar',
                                emphasis: {
                                    focus: 'series'
                                },
                                data: this.rate,
                                itemStyle: {
                                    normal: {
                                        color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
                                            // 四个数字分别对应 数组中颜色的开始位置，分别为 右，下，左，上。例如（1,0,0,0 ）代表从右边开始渐
                                            // 变。offset取值为0~1，0代表开始时的颜色，1代表结束时的颜色，柱子表现为这两种颜色的渐变。
                                            offset: 0,
                                            color: '#141cce'
                                        }, {
                                            offset: 1,
                                            color: '#0e1386'
                                        }]),
                                        label: {
                                            formatter: '{c}',
                                            show: true,
                                            position: 'top',
                                            textStyle: {
                                                fontSize: '10',
                                                color: '#fff',
                                            },
                                        },
                                    },

                                },
                            },
                        ]
                    };
                    // this.DyeingAndFinishingoption && this.DyeingAndFinishingmyChart.setOption(this.DyeingAndFinishingoption);
                },
                throttle(fn, delay) {
                    var n = null; return function () { var t = this, r = arguments; clearTimeout(n), n = setTimeout(function () { fn.apply(t, r) }, delay) }
                },
                setScale() {
                    const t = this.$refs["screen-wrap"], e = 1920, o = 1080, d = parseFloat((e / o).toFixed(5)), a = parseFloat((window.innerWidth / window.innerHeight).toFixed(5)); if (a > d) { const r = (window.innerHeight / o).toFixed(5); t.style.transform = `scale(${r},${r}) translate(-50%,-50%)` } else { const r = (window.innerWidth / e).toFixed(5); t.style.transform = `scale(${r},${r}) translate(-50%,-50%)` }
                },
            },
        });
    </script>
</body>

</html>